package com.suse.warmstill.vo;

import javax.validation.constraints.Min;
import javax.validation.constraints.NotNull;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.io.Serializable;

/**
 * 分页工具类
 */
@Data
@ApiModel("分页工具类")
public class ConditionVO extends BaseVo {

    /**
     * 搜索内容
     */
    @ApiModelProperty(name = "keyword", value = "搜索内容", required = false)
    private String keyword;

    /**
     * 页码
     */
    @ApiModelProperty(name = "current", value = "页码", dataType = "Long")
    @Min(value = 1, message = "页码不能小于1")
    @NotNull(message = "页码不能为空")
    private Long current;

    /**
     * 条数
     */
    @ApiModelProperty(name = "size", value = "条数", dataType = "Long")
    @Min(value = 1, message = "条数不能小于1")
    @NotNull(message = "条数不能为空")
    private Long size;

}
